<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.9.1"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>Doxygen: doc/tutorials/content/sources/iccv2011/include/feature_estimation.h 源文件</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">Doxygen
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- 制作者 Doxygen 1.9.1 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'搜索','.html');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
  initMenu('',true,false,'search.php','搜索');
  $(document).ready(function() { init_search(); });
});
/* @license-end */</script>
<div id="main-nav"></div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(document).ready(function(){initNavTree('iccv2011_2include_2feature__estimation_8h_source.html',''); initResizable(); });
/* @license-end */
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="headertitle">
<div class="title">feature_estimation.h</div>  </div>
</div><!--header-->
<div class="contents">
<div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno">    1</span>&#160;<span class="preprocessor">#ifndef FEATURE_ESTIMATION_H</span></div>
<div class="line"><a name="l00002"></a><span class="lineno">    2</span>&#160;<span class="preprocessor">#define FEATURE_ESTIMATION_H</span></div>
<div class="line"><a name="l00003"></a><span class="lineno">    3</span>&#160; </div>
<div class="line"><a name="l00004"></a><span class="lineno">    4</span>&#160;<span class="preprocessor">#include &quot;typedefs.h&quot;</span></div>
<div class="line"><a name="l00005"></a><span class="lineno">    5</span>&#160; </div>
<div class="line"><a name="l00006"></a><span class="lineno">    6</span>&#160;<span class="preprocessor">#include &lt;pcl/io/io.h&gt;</span></div>
<div class="line"><a name="l00007"></a><span class="lineno">    7</span>&#160;<span class="preprocessor">#include &lt;pcl/features/normal_3d.h&gt;</span></div>
<div class="line"><a name="l00008"></a><span class="lineno">    8</span>&#160;<span class="preprocessor">#include &lt;pcl/keypoints/sift_keypoint.h&gt;</span></div>
<div class="line"><a name="l00009"></a><span class="lineno">    9</span>&#160;<span class="preprocessor">#include &lt;pcl/features/fpfh.h&gt;</span></div>
<div class="line"><a name="l00010"></a><span class="lineno">   10</span>&#160;<span class="preprocessor">#include &lt;pcl/features/vfh.h&gt;</span></div>
<div class="line"><a name="l00011"></a><span class="lineno">   11</span>&#160;<span class="preprocessor">#include &lt;pcl/search/kdtree.h&gt;</span></div>
<div class="line"><a name="l00012"></a><span class="lineno">   12</span>&#160;<span class="comment">/* Use NormalEstimation to estimate a cloud&#39;s surface normals </span></div>
<div class="line"><a name="l00013"></a><span class="lineno">   13</span>&#160;<span class="comment"> * Inputs:</span></div>
<div class="line"><a name="l00014"></a><span class="lineno">   14</span>&#160;<span class="comment"> *   input</span></div>
<div class="line"><a name="l00015"></a><span class="lineno">   15</span>&#160;<span class="comment"> *     The input point cloud</span></div>
<div class="line"><a name="l00016"></a><span class="lineno">   16</span>&#160;<span class="comment"> *   radius</span></div>
<div class="line"><a name="l00017"></a><span class="lineno">   17</span>&#160;<span class="comment"> *     The size of the local neighborhood used to estimate the surface</span></div>
<div class="line"><a name="l00018"></a><span class="lineno">   18</span>&#160;<span class="comment"> * Return: A pointer to a SurfaceNormals point cloud</span></div>
<div class="line"><a name="l00019"></a><span class="lineno">   19</span>&#160;<span class="comment"> */</span></div>
<div class="line"><a name="l00020"></a><span class="lineno">   20</span>&#160;SurfaceNormalsPtr</div>
<div class="line"><a name="l00021"></a><span class="lineno">   21</span>&#160;estimateSurfaceNormals (<span class="keyword">const</span> PointCloudPtr &amp; input, <span class="keywordtype">float</span> radius)</div>
<div class="line"><a name="l00022"></a><span class="lineno">   22</span>&#160;{</div>
<div class="line"><a name="l00023"></a><span class="lineno">   23</span>&#160;  <a class="code" href="classpcl_1_1_normal_estimation.html">pcl::NormalEstimation&lt;PointT, NormalT&gt;</a> normal_estimation;</div>
<div class="line"><a name="l00024"></a><span class="lineno">   24</span>&#160;  normal_estimation.<a class="code" href="classpcl_1_1_feature.html#ace1caca622f06eee8ad1911228324792">setSearchMethod</a> (pcl::search::Search&lt;PointT&gt;::Ptr (<span class="keyword">new</span> <a class="code" href="classpcl_1_1search_1_1_kd_tree.html">pcl::search::KdTree&lt;PointT&gt;</a>));</div>
<div class="line"><a name="l00025"></a><span class="lineno">   25</span>&#160;  normal_estimation.<a class="code" href="classpcl_1_1_feature.html#a44829319486a2dc415a4e068dc55c577">setRadiusSearch</a> (radius);</div>
<div class="line"><a name="l00026"></a><span class="lineno">   26</span>&#160;  normal_estimation.<a class="code" href="classpcl_1_1_normal_estimation.html#ac92dbbea9d923754b3d87d981a6bd131">setInputCloud</a> (input);</div>
<div class="line"><a name="l00027"></a><span class="lineno">   27</span>&#160;  SurfaceNormalsPtr normals (<span class="keyword">new</span> <a class="code" href="classpcl_1_1_point_cloud.html">SurfaceNormals</a>);</div>
<div class="line"><a name="l00028"></a><span class="lineno">   28</span>&#160;  normal_estimation.<a class="code" href="classpcl_1_1_feature.html#ad5b1fa9612da40e738b1d99252c5ff2f">compute</a> (*normals);</div>
<div class="line"><a name="l00029"></a><span class="lineno">   29</span>&#160; </div>
<div class="line"><a name="l00030"></a><span class="lineno">   30</span>&#160;  <span class="keywordflow">return</span> (normals);</div>
<div class="line"><a name="l00031"></a><span class="lineno">   31</span>&#160;}</div>
<div class="line"><a name="l00032"></a><span class="lineno">   32</span>&#160; </div>
<div class="line"><a name="l00033"></a><span class="lineno">   33</span>&#160;<span class="comment">/* Use SIFTKeypoint to detect a set of keypoints</span></div>
<div class="line"><a name="l00034"></a><span class="lineno">   34</span>&#160;<span class="comment"> * Inputs:</span></div>
<div class="line"><a name="l00035"></a><span class="lineno">   35</span>&#160;<span class="comment"> *   points</span></div>
<div class="line"><a name="l00036"></a><span class="lineno">   36</span>&#160;<span class="comment"> *     The input point cloud</span></div>
<div class="line"><a name="l00037"></a><span class="lineno">   37</span>&#160;<span class="comment"> *   normals</span></div>
<div class="line"><a name="l00038"></a><span class="lineno">   38</span>&#160;<span class="comment"> *     The input surface normals</span></div>
<div class="line"><a name="l00039"></a><span class="lineno">   39</span>&#160;<span class="comment"> *   min_scale</span></div>
<div class="line"><a name="l00040"></a><span class="lineno">   40</span>&#160;<span class="comment"> *     The smallest scale in the difference-of-Gaussians (DoG) scale-space</span></div>
<div class="line"><a name="l00041"></a><span class="lineno">   41</span>&#160;<span class="comment"> *   nr_octaves</span></div>
<div class="line"><a name="l00042"></a><span class="lineno">   42</span>&#160;<span class="comment"> *     The number of times the scale doubles in the DoG scale-space</span></div>
<div class="line"><a name="l00043"></a><span class="lineno">   43</span>&#160;<span class="comment"> *   nr_scales_per_octave</span></div>
<div class="line"><a name="l00044"></a><span class="lineno">   44</span>&#160;<span class="comment"> *     The number of scales computed for each doubling</span></div>
<div class="line"><a name="l00045"></a><span class="lineno">   45</span>&#160;<span class="comment"> *   min_contrast</span></div>
<div class="line"><a name="l00046"></a><span class="lineno">   46</span>&#160;<span class="comment"> *     The minimum local contrast that must be present for a keypoint to be detected</span></div>
<div class="line"><a name="l00047"></a><span class="lineno">   47</span>&#160;<span class="comment"> * Return: A pointer to a point cloud of keypoints</span></div>
<div class="line"><a name="l00048"></a><span class="lineno">   48</span>&#160;<span class="comment"> */</span></div>
<div class="line"><a name="l00049"></a><span class="lineno">   49</span>&#160;PointCloudPtr</div>
<div class="line"><a name="l00050"></a><span class="lineno">   50</span>&#160;detectKeypoints (<span class="keyword">const</span> PointCloudPtr &amp; points, <span class="keyword">const</span> SurfaceNormalsPtr &amp; normals,</div>
<div class="line"><a name="l00051"></a><span class="lineno">   51</span>&#160;                 <span class="keywordtype">float</span> min_scale, <span class="keywordtype">int</span> nr_octaves, <span class="keywordtype">int</span> nr_scales_per_octave, <span class="keywordtype">float</span> min_contrast)</div>
<div class="line"><a name="l00052"></a><span class="lineno">   52</span>&#160;{</div>
<div class="line"><a name="l00053"></a><span class="lineno">   53</span>&#160;  <a class="code" href="classpcl_1_1_s_i_f_t_keypoint.html">pcl::SIFTKeypoint&lt;PointT, pcl::PointWithScale&gt;</a> sift_detect;</div>
<div class="line"><a name="l00054"></a><span class="lineno">   54</span>&#160;  sift_detect.<a class="code" href="classpcl_1_1_keypoint.html#a153d731738fd5966e169e26b61013689">setSearchMethod</a> (pcl::search::Search&lt;PointT&gt;::Ptr (<span class="keyword">new</span> <a class="code" href="classpcl_1_1search_1_1_kd_tree.html">pcl::search::KdTree&lt;PointT&gt;</a>));</div>
<div class="line"><a name="l00055"></a><span class="lineno">   55</span>&#160;  sift_detect.<a class="code" href="classpcl_1_1_s_i_f_t_keypoint.html#aa7b165d782eca9c9d226504b84729439">setScales</a> (min_scale, nr_octaves, nr_scales_per_octave);</div>
<div class="line"><a name="l00056"></a><span class="lineno">   56</span>&#160;  sift_detect.<a class="code" href="classpcl_1_1_s_i_f_t_keypoint.html#a5fcabfa4b90cc77cf0c18a5b263d06a0">setMinimumContrast</a> (min_contrast);</div>
<div class="line"><a name="l00057"></a><span class="lineno">   57</span>&#160;  sift_detect.<a class="code" href="classpcl_1_1_p_c_l_base.html#a1952d7101f3942bac3b69ed55c1ca7ea">setInputCloud</a> (points);</div>
<div class="line"><a name="l00058"></a><span class="lineno">   58</span>&#160;  <a class="code" href="classpcl_1_1_point_cloud.html">pcl::PointCloud&lt;pcl::PointWithScale&gt;</a> keypoints_temp;</div>
<div class="line"><a name="l00059"></a><span class="lineno">   59</span>&#160;  sift_detect.<a class="code" href="classpcl_1_1_keypoint.html#a046a7cd11598b06d2076da69a3100e4b">compute</a> (keypoints_temp);</div>
<div class="line"><a name="l00060"></a><span class="lineno">   60</span>&#160;  PointCloudPtr keypoints (<span class="keyword">new</span> <a class="code" href="classpcl_1_1_point_cloud.html">PointCloud</a>);</div>
<div class="line"><a name="l00061"></a><span class="lineno">   61</span>&#160;  <a class="code" href="group__common.html#gaa65b1c8d782e7b776ae682679d2d948f">pcl::copyPointCloud</a> (keypoints_temp, *keypoints);</div>
<div class="line"><a name="l00062"></a><span class="lineno">   62</span>&#160; </div>
<div class="line"><a name="l00063"></a><span class="lineno">   63</span>&#160;  <span class="keywordflow">return</span> (keypoints);</div>
<div class="line"><a name="l00064"></a><span class="lineno">   64</span>&#160;}</div>
<div class="line"><a name="l00065"></a><span class="lineno">   65</span>&#160; </div>
<div class="line"><a name="l00066"></a><span class="lineno">   66</span>&#160;<span class="comment">/* Use FPFHEstimation to compute local feature descriptors around each keypoint</span></div>
<div class="line"><a name="l00067"></a><span class="lineno">   67</span>&#160;<span class="comment"> * Inputs:</span></div>
<div class="line"><a name="l00068"></a><span class="lineno">   68</span>&#160;<span class="comment"> *   points</span></div>
<div class="line"><a name="l00069"></a><span class="lineno">   69</span>&#160;<span class="comment"> *     The input point cloud</span></div>
<div class="line"><a name="l00070"></a><span class="lineno">   70</span>&#160;<span class="comment"> *   normals</span></div>
<div class="line"><a name="l00071"></a><span class="lineno">   71</span>&#160;<span class="comment"> *     The input surface normals</span></div>
<div class="line"><a name="l00072"></a><span class="lineno">   72</span>&#160;<span class="comment"> *   keypoints</span></div>
<div class="line"><a name="l00073"></a><span class="lineno">   73</span>&#160;<span class="comment"> *     A cloud of keypoints specifying the positions at which the descriptors should be computed</span></div>
<div class="line"><a name="l00074"></a><span class="lineno">   74</span>&#160;<span class="comment"> *   feature_radius</span></div>
<div class="line"><a name="l00075"></a><span class="lineno">   75</span>&#160;<span class="comment"> *     The size of the neighborhood from which the local descriptors will be computed </span></div>
<div class="line"><a name="l00076"></a><span class="lineno">   76</span>&#160;<span class="comment"> * Return: A pointer to a LocalDescriptors (a cloud of LocalDescriptorT points)</span></div>
<div class="line"><a name="l00077"></a><span class="lineno">   77</span>&#160;<span class="comment"> */</span></div>
<div class="line"><a name="l00078"></a><span class="lineno">   78</span>&#160;LocalDescriptorsPtr</div>
<div class="line"><a name="l00079"></a><span class="lineno">   79</span>&#160;computeLocalDescriptors (<span class="keyword">const</span> PointCloudPtr &amp; points, <span class="keyword">const</span> SurfaceNormalsPtr &amp; normals, </div>
<div class="line"><a name="l00080"></a><span class="lineno">   80</span>&#160;                         <span class="keyword">const</span> PointCloudPtr &amp; keypoints, <span class="keywordtype">float</span> feature_radius)</div>
<div class="line"><a name="l00081"></a><span class="lineno">   81</span>&#160;{</div>
<div class="line"><a name="l00082"></a><span class="lineno">   82</span>&#160;  <a class="code" href="classpcl_1_1_f_p_f_h_estimation.html">pcl::FPFHEstimation&lt;PointT, NormalT, LocalDescriptorT&gt;</a> fpfh_estimation;</div>
<div class="line"><a name="l00083"></a><span class="lineno">   83</span>&#160;  fpfh_estimation.<a class="code" href="classpcl_1_1_feature.html#ace1caca622f06eee8ad1911228324792">setSearchMethod</a> (pcl::search::Search&lt;PointT&gt;::Ptr (<span class="keyword">new</span> <a class="code" href="classpcl_1_1search_1_1_kd_tree.html">pcl::search::KdTree&lt;PointT&gt;</a>));</div>
<div class="line"><a name="l00084"></a><span class="lineno">   84</span>&#160;  fpfh_estimation.<a class="code" href="classpcl_1_1_feature.html#a44829319486a2dc415a4e068dc55c577">setRadiusSearch</a> (feature_radius);</div>
<div class="line"><a name="l00085"></a><span class="lineno">   85</span>&#160;  fpfh_estimation.<a class="code" href="classpcl_1_1_feature.html#a14fbb05e0e8f1d1ec766a50353f3c224">setSearchSurface</a> (points);  </div>
<div class="line"><a name="l00086"></a><span class="lineno">   86</span>&#160;  fpfh_estimation.<a class="code" href="classpcl_1_1_feature_from_normals.html#a349685ac9deb723502de9f399d0286dc">setInputNormals</a> (normals);</div>
<div class="line"><a name="l00087"></a><span class="lineno">   87</span>&#160;  fpfh_estimation.<a class="code" href="classpcl_1_1_p_c_l_base.html#a1952d7101f3942bac3b69ed55c1ca7ea">setInputCloud</a> (keypoints);</div>
<div class="line"><a name="l00088"></a><span class="lineno">   88</span>&#160;  LocalDescriptorsPtr local_descriptors (<span class="keyword">new</span> <a class="code" href="classpcl_1_1_point_cloud.html">LocalDescriptors</a>);</div>
<div class="line"><a name="l00089"></a><span class="lineno">   89</span>&#160;  fpfh_estimation.<a class="code" href="classpcl_1_1_feature.html#ad5b1fa9612da40e738b1d99252c5ff2f">compute</a> (*local_descriptors);</div>
<div class="line"><a name="l00090"></a><span class="lineno">   90</span>&#160; </div>
<div class="line"><a name="l00091"></a><span class="lineno">   91</span>&#160;  <span class="keywordflow">return</span> (local_descriptors);</div>
<div class="line"><a name="l00092"></a><span class="lineno">   92</span>&#160;}</div>
<div class="line"><a name="l00093"></a><span class="lineno">   93</span>&#160; </div>
<div class="line"><a name="l00094"></a><span class="lineno">   94</span>&#160;<span class="comment">/* Use VFHEstimation to compute a single global descriptor for the entire input cloud</span></div>
<div class="line"><a name="l00095"></a><span class="lineno">   95</span>&#160;<span class="comment"> * Inputs:</span></div>
<div class="line"><a name="l00096"></a><span class="lineno">   96</span>&#160;<span class="comment"> *   points</span></div>
<div class="line"><a name="l00097"></a><span class="lineno">   97</span>&#160;<span class="comment"> *     The input point cloud</span></div>
<div class="line"><a name="l00098"></a><span class="lineno">   98</span>&#160;<span class="comment"> *   normals</span></div>
<div class="line"><a name="l00099"></a><span class="lineno">   99</span>&#160;<span class="comment"> *     The input surface normals</span></div>
<div class="line"><a name="l00100"></a><span class="lineno">  100</span>&#160;<span class="comment"> * Return: A pointer to a GlobalDescriptors point cloud (a cloud containing a single GlobalDescriptorT point)</span></div>
<div class="line"><a name="l00101"></a><span class="lineno">  101</span>&#160;<span class="comment"> */</span></div>
<div class="line"><a name="l00102"></a><span class="lineno">  102</span>&#160;GlobalDescriptorsPtr</div>
<div class="line"><a name="l00103"></a><span class="lineno">  103</span>&#160;computeGlobalDescriptor (<span class="keyword">const</span> PointCloudPtr &amp; points, <span class="keyword">const</span> SurfaceNormalsPtr &amp; normals)</div>
<div class="line"><a name="l00104"></a><span class="lineno">  104</span>&#160;{</div>
<div class="line"><a name="l00105"></a><span class="lineno">  105</span>&#160;  <a class="code" href="classpcl_1_1_v_f_h_estimation.html">pcl::VFHEstimation&lt;PointT, NormalT, GlobalDescriptorT&gt;</a> vfh_estimation;</div>
<div class="line"><a name="l00106"></a><span class="lineno">  106</span>&#160;  vfh_estimation.<a class="code" href="classpcl_1_1_feature.html#ace1caca622f06eee8ad1911228324792">setSearchMethod</a> (pcl::search::Search&lt;PointT&gt;::Ptr (<span class="keyword">new</span> <a class="code" href="classpcl_1_1search_1_1_kd_tree.html">pcl::search::KdTree&lt;PointT&gt;</a>));</div>
<div class="line"><a name="l00107"></a><span class="lineno">  107</span>&#160;  vfh_estimation.<a class="code" href="classpcl_1_1_p_c_l_base.html#a1952d7101f3942bac3b69ed55c1ca7ea">setInputCloud</a> (points);</div>
<div class="line"><a name="l00108"></a><span class="lineno">  108</span>&#160;  vfh_estimation.<a class="code" href="classpcl_1_1_feature_from_normals.html#a349685ac9deb723502de9f399d0286dc">setInputNormals</a> (normals);</div>
<div class="line"><a name="l00109"></a><span class="lineno">  109</span>&#160;  GlobalDescriptorsPtr global_descriptor (<span class="keyword">new</span> <a class="code" href="classpcl_1_1_point_cloud.html">GlobalDescriptors</a>);</div>
<div class="line"><a name="l00110"></a><span class="lineno">  110</span>&#160;  vfh_estimation.<a class="code" href="classpcl_1_1_v_f_h_estimation.html#a8ad7f79ee618d1a6f9bca5d579c36130">compute</a> (*global_descriptor);</div>
<div class="line"><a name="l00111"></a><span class="lineno">  111</span>&#160; </div>
<div class="line"><a name="l00112"></a><span class="lineno">  112</span>&#160;  <span class="keywordflow">return</span> (global_descriptor);</div>
<div class="line"><a name="l00113"></a><span class="lineno">  113</span>&#160;}</div>
<div class="line"><a name="l00114"></a><span class="lineno">  114</span>&#160; </div>
<div class="line"><a name="l00115"></a><span class="lineno">  115</span>&#160;<span class="comment">/* A simple structure for storing all of a cloud&#39;s features */</span></div>
<div class="line"><a name="l00116"></a><span class="lineno"><a class="line" href="struct_object_features.html">  116</a></span>&#160;<span class="keyword">struct </span><a class="code" href="struct_object_features.html">ObjectFeatures</a></div>
<div class="line"><a name="l00117"></a><span class="lineno">  117</span>&#160;{</div>
<div class="line"><a name="l00118"></a><span class="lineno">  118</span>&#160;  PointCloudPtr points;</div>
<div class="line"><a name="l00119"></a><span class="lineno">  119</span>&#160;  SurfaceNormalsPtr normals;</div>
<div class="line"><a name="l00120"></a><span class="lineno">  120</span>&#160;  PointCloudPtr keypoints;</div>
<div class="line"><a name="l00121"></a><span class="lineno">  121</span>&#160;  LocalDescriptorsPtr local_descriptors;</div>
<div class="line"><a name="l00122"></a><span class="lineno">  122</span>&#160;  GlobalDescriptorsPtr global_descriptor;</div>
<div class="line"><a name="l00123"></a><span class="lineno">  123</span>&#160;};</div>
<div class="line"><a name="l00124"></a><span class="lineno">  124</span>&#160; </div>
<div class="line"><a name="l00125"></a><span class="lineno">  125</span>&#160;<span class="comment">/* Estimate normals, detect keypoints, and compute local and global descriptors </span></div>
<div class="line"><a name="l00126"></a><span class="lineno">  126</span>&#160;<span class="comment"> * Return: An ObjectFeatures struct containing all the features</span></div>
<div class="line"><a name="l00127"></a><span class="lineno">  127</span>&#160;<span class="comment"> */</span></div>
<div class="line"><a name="l00128"></a><span class="lineno">  128</span>&#160;<a class="code" href="struct_object_features.html">ObjectFeatures</a></div>
<div class="line"><a name="l00129"></a><span class="lineno">  129</span>&#160;computeFeatures (<span class="keyword">const</span> PointCloudPtr &amp; input)</div>
<div class="line"><a name="l00130"></a><span class="lineno">  130</span>&#160;{</div>
<div class="line"><a name="l00131"></a><span class="lineno">  131</span>&#160;  <a class="code" href="struct_object_features.html">ObjectFeatures</a> features;</div>
<div class="line"><a name="l00132"></a><span class="lineno">  132</span>&#160;  features.points = input;</div>
<div class="line"><a name="l00133"></a><span class="lineno">  133</span>&#160;  features.normals = estimateSurfaceNormals (input, 0.05);</div>
<div class="line"><a name="l00134"></a><span class="lineno">  134</span>&#160;  features.keypoints = detectKeypoints (input, features.normals, 0.005, 10, 8, 1.5);</div>
<div class="line"><a name="l00135"></a><span class="lineno">  135</span>&#160;  features.local_descriptors = computeLocalDescriptors (input, features.normals, features.keypoints, 0.1);</div>
<div class="line"><a name="l00136"></a><span class="lineno">  136</span>&#160;  features.global_descriptor = computeGlobalDescriptor (input, features.normals);</div>
<div class="line"><a name="l00137"></a><span class="lineno">  137</span>&#160; </div>
<div class="line"><a name="l00138"></a><span class="lineno">  138</span>&#160;  <span class="keywordflow">return</span> (features);</div>
<div class="line"><a name="l00139"></a><span class="lineno">  139</span>&#160;}</div>
<div class="line"><a name="l00140"></a><span class="lineno">  140</span>&#160; </div>
<div class="line"><a name="l00141"></a><span class="lineno">  141</span>&#160;<span class="preprocessor">#endif</span></div>
<div class="ttc" id="aclasspcl_1_1_f_p_f_h_estimation_html"><div class="ttname"><a href="classpcl_1_1_f_p_f_h_estimation.html">pcl::FPFHEstimation</a></div><div class="ttdoc">FPFHEstimation estimates the Fast Point Feature Histogram (FPFH) descriptor for a given point cloud d...</div><div class="ttdef"><b>Definition:</b> fpfh.h:81</div></div>
<div class="ttc" id="aclasspcl_1_1_feature_from_normals_html_a349685ac9deb723502de9f399d0286dc"><div class="ttname"><a href="classpcl_1_1_feature_from_normals.html#a349685ac9deb723502de9f399d0286dc">pcl::FeatureFromNormals::setInputNormals</a></div><div class="ttdeci">void setInputNormals(const PointCloudNConstPtr &amp;normals)</div><div class="ttdoc">Provide a pointer to the input dataset that contains the point normals of the XYZ dataset....</div><div class="ttdef"><b>Definition:</b> feature.h:344</div></div>
<div class="ttc" id="aclasspcl_1_1_feature_html_a14fbb05e0e8f1d1ec766a50353f3c224"><div class="ttname"><a href="classpcl_1_1_feature.html#a14fbb05e0e8f1d1ec766a50353f3c224">pcl::Feature::setSearchSurface</a></div><div class="ttdeci">void setSearchSurface(const PointCloudInConstPtr &amp;cloud)</div><div class="ttdoc">Provide a pointer to a dataset to add additional information to estimate the features for every point...</div><div class="ttdef"><b>Definition:</b> feature.h:148</div></div>
<div class="ttc" id="aclasspcl_1_1_feature_html_a44829319486a2dc415a4e068dc55c577"><div class="ttname"><a href="classpcl_1_1_feature.html#a44829319486a2dc415a4e068dc55c577">pcl::Feature::setRadiusSearch</a></div><div class="ttdeci">void setRadiusSearch(double radius)</div><div class="ttdoc">Set the sphere radius that is to be used for determining the nearest neighbors used for the feature e...</div><div class="ttdef"><b>Definition:</b> feature.h:200</div></div>
<div class="ttc" id="aclasspcl_1_1_feature_html_ace1caca622f06eee8ad1911228324792"><div class="ttname"><a href="classpcl_1_1_feature.html#ace1caca622f06eee8ad1911228324792">pcl::Feature::setSearchMethod</a></div><div class="ttdeci">void setSearchMethod(const KdTreePtr &amp;tree)</div><div class="ttdoc">Provide a pointer to the search object.</div><div class="ttdef"><b>Definition:</b> feature.h:166</div></div>
<div class="ttc" id="aclasspcl_1_1_feature_html_ad5b1fa9612da40e738b1d99252c5ff2f"><div class="ttname"><a href="classpcl_1_1_feature.html#ad5b1fa9612da40e738b1d99252c5ff2f">pcl::Feature::compute</a></div><div class="ttdeci">void compute(PointCloudOut &amp;output)</div><div class="ttdoc">Base method for feature estimation for all points given in &lt;setInputCloud (), setIndices ()&gt; using th...</div><div class="ttdef"><b>Definition:</b> feature.hpp:189</div></div>
<div class="ttc" id="aclasspcl_1_1_keypoint_html_a046a7cd11598b06d2076da69a3100e4b"><div class="ttname"><a href="classpcl_1_1_keypoint.html#a046a7cd11598b06d2076da69a3100e4b">pcl::Keypoint::compute</a></div><div class="ttdeci">void compute(PointCloudOut &amp;output)</div><div class="ttdoc">Base method for key point detection for all points given in &lt;setInputCloud (), setIndices ()&gt; using t...</div><div class="ttdef"><b>Definition:</b> keypoint.hpp:124</div></div>
<div class="ttc" id="aclasspcl_1_1_keypoint_html_a153d731738fd5966e169e26b61013689"><div class="ttname"><a href="classpcl_1_1_keypoint.html#a153d731738fd5966e169e26b61013689">pcl::Keypoint::setSearchMethod</a></div><div class="ttdeci">void setSearchMethod(const KdTreePtr &amp;tree)</div><div class="ttdoc">Provide a pointer to the search object.</div><div class="ttdef"><b>Definition:</b> keypoint.h:105</div></div>
<div class="ttc" id="aclasspcl_1_1_normal_estimation_html"><div class="ttname"><a href="classpcl_1_1_normal_estimation.html">pcl::NormalEstimation</a></div><div class="ttdoc">NormalEstimation estimates local surface properties (surface normals and curvatures)at each 3D point....</div><div class="ttdef"><b>Definition:</b> normal_3d.h:200</div></div>
<div class="ttc" id="aclasspcl_1_1_normal_estimation_html_ac92dbbea9d923754b3d87d981a6bd131"><div class="ttname"><a href="classpcl_1_1_normal_estimation.html#ac92dbbea9d923754b3d87d981a6bd131">pcl::NormalEstimation::setInputCloud</a></div><div class="ttdeci">virtual void setInputCloud(const PointCloudConstPtr &amp;cloud)</div><div class="ttdoc">Provide a pointer to the input dataset</div><div class="ttdef"><b>Definition:</b> normal_3d.h:290</div></div>
<div class="ttc" id="aclasspcl_1_1_p_c_l_base_html_a1952d7101f3942bac3b69ed55c1ca7ea"><div class="ttname"><a href="classpcl_1_1_p_c_l_base.html#a1952d7101f3942bac3b69ed55c1ca7ea">pcl::PCLBase::setInputCloud</a></div><div class="ttdeci">virtual void setInputCloud(const PointCloudConstPtr &amp;cloud)</div><div class="ttdoc">Provide a pointer to the input dataset</div><div class="ttdef"><b>Definition:</b> pcl_base.hpp:66</div></div>
<div class="ttc" id="aclasspcl_1_1_point_cloud_html"><div class="ttname"><a href="classpcl_1_1_point_cloud.html">pcl::PointCloud&lt; NormalT &gt;</a></div></div>
<div class="ttc" id="aclasspcl_1_1_s_i_f_t_keypoint_html"><div class="ttname"><a href="classpcl_1_1_s_i_f_t_keypoint.html">pcl::SIFTKeypoint</a></div><div class="ttdoc">SIFTKeypoint detects the Scale Invariant Feature Transform keypoints for a given point cloud dataset ...</div><div class="ttdef"><b>Definition:</b> sift_keypoint.h:95</div></div>
<div class="ttc" id="aclasspcl_1_1_s_i_f_t_keypoint_html_a5fcabfa4b90cc77cf0c18a5b263d06a0"><div class="ttname"><a href="classpcl_1_1_s_i_f_t_keypoint.html#a5fcabfa4b90cc77cf0c18a5b263d06a0">pcl::SIFTKeypoint::setMinimumContrast</a></div><div class="ttdeci">void setMinimumContrast(float min_contrast)</div><div class="ttdoc">Provide a threshold to limit detection of keypoints without sufficient contrast</div><div class="ttdef"><b>Definition:</b> sift_keypoint.hpp:57</div></div>
<div class="ttc" id="aclasspcl_1_1_s_i_f_t_keypoint_html_aa7b165d782eca9c9d226504b84729439"><div class="ttname"><a href="classpcl_1_1_s_i_f_t_keypoint.html#aa7b165d782eca9c9d226504b84729439">pcl::SIFTKeypoint::setScales</a></div><div class="ttdeci">void setScales(float min_scale, int nr_octaves, int nr_scales_per_octave)</div><div class="ttdoc">Specify the range of scales over which to search for keypoints</div><div class="ttdef"><b>Definition:</b> sift_keypoint.hpp:47</div></div>
<div class="ttc" id="aclasspcl_1_1_v_f_h_estimation_html"><div class="ttname"><a href="classpcl_1_1_v_f_h_estimation.html">pcl::VFHEstimation</a></div><div class="ttdoc">VFHEstimation estimates the Viewpoint Feature Histogram (VFH) descriptor for a given point cloud data...</div><div class="ttdef"><b>Definition:</b> vfh.h:72</div></div>
<div class="ttc" id="aclasspcl_1_1_v_f_h_estimation_html_a8ad7f79ee618d1a6f9bca5d579c36130"><div class="ttname"><a href="classpcl_1_1_v_f_h_estimation.html#a8ad7f79ee618d1a6f9bca5d579c36130">pcl::VFHEstimation::compute</a></div><div class="ttdeci">void compute(PointCloudOut &amp;output)</div><div class="ttdoc">Overloaded computed method from pcl::Feature.</div><div class="ttdef"><b>Definition:</b> vfh.hpp:65</div></div>
<div class="ttc" id="aclasspcl_1_1search_1_1_kd_tree_html"><div class="ttname"><a href="classpcl_1_1search_1_1_kd_tree.html">pcl::search::KdTree</a></div><div class="ttdoc">search::KdTree is a wrapper class which inherits the pcl::KdTree class for performing search function...</div><div class="ttdef"><b>Definition:</b> kdtree.h:63</div></div>
<div class="ttc" id="agroup__common_html_gaa65b1c8d782e7b776ae682679d2d948f"><div class="ttname"><a href="group__common.html#gaa65b1c8d782e7b776ae682679d2d948f">pcl::copyPointCloud</a></div><div class="ttdeci">PCL_EXPORTS void copyPointCloud(const pcl::PCLPointCloud2 &amp;cloud_in, const std::vector&lt; int &gt; &amp;indices, pcl::PCLPointCloud2 &amp;cloud_out)</div><div class="ttdoc">Extract the indices of a given point cloud as a new point cloud</div></div>
<div class="ttc" id="astruct_object_features_html"><div class="ttname"><a href="struct_object_features.html">ObjectFeatures</a></div><div class="ttdef"><b>Definition:</b> feature_estimation.h:117</div></div>
</div><!-- fragment --></div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><a class="el" href="dir_e68e8157741866f444e17edd764ebbae.html">doc</a></li><li class="navelem"><a class="el" href="dir_5b0b179e83013be2ae877b5cea1eb6e2.html">tutorials</a></li><li class="navelem"><a class="el" href="dir_e680b2aa8c25f53365b84c58875b1c5f.html">content</a></li><li class="navelem"><a class="el" href="dir_532239a1d34197dad6a28d101a9d1eb1.html">sources</a></li><li class="navelem"><a class="el" href="dir_72091b6be856e2c48ba392fbb6348f26.html">iccv2011</a></li><li class="navelem"><a class="el" href="dir_23d34f47c6e88aa653f014de7cd4575b.html">include</a></li><li class="navelem"><b>feature_estimation.h</b></li>
    <li class="footer">制作者 <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.1 </li>
  </ul>
</div>
</body>
</html>
